<?xml version="1.0" encoding="UTF-8"?>

<!DOCTYPE hibernate-mapping PUBLIC
    "-//Hibernate/Hibernate Mapping DTD 3.0//EN" 
    "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">

<hibernate-mapping>
        <class name="cn.firstsoft.modules.loge.domain.LogeBed" table="loge_bed">
        <id name="id" type="integer">
            <column name="id" />
            <generator class="native" >
				<param name="sequence">LOGE_BED_ID_SEQ</param>
            </generator>
        </id>
        <property name="no" type="integer">
            <column name="no" length="50" />
        </property>
        <property name="status" type="string">
            <column name="status" length="50" />
        </property>
        <property name="useing" type="string">
            <column name="useing" length="50" />
        </property>
        <set name="logeRecord" inverse="true" cascade="all">
            <key>
                <column name="loge_id" />
            </key>
            <one-to-many class="cn.firstsoft.modules.loge.domain.LogeRecord" />
        </set>
        <many-to-one name="logeRoom" class="cn.firstsoft.modules.loge.domain.LogeRoom" fetch="select">
            <column name="room_id"/>
        </many-to-one>
    </class>
</hibernate-mapping>
